package com.angel.entity;

import java.util.ArrayList;
import java.util.List;

import com.angel.entity.bean.Activity;
import com.angel.entity.bean.ActivityImg;
import com.angel.entity.bean.Status;

public class ActivityDetailBean extends ActivityBean {
	private static final long serialVersionUID = -4722393896866479124L;
	// 获取是否成功
	private String isSucess;
	// 活动详情上图片地址
	private String detailMainImgUrl;
	// 活动主办方
	private String activityHost;
	// 活动所有相关小图片
	private List<String> allActivityUrl;
	// 活动所有相关大图片
	private List<String> allActivityBigUrl;
	// 活动介绍
	private String activityDescription;
	// 是否感兴趣
	private String isInterest;
	// 是否参加
	private String isParticipate;

	public ActivityDetailBean() {
		this.isSucess = "0";
	}

	public ActivityDetailBean(Activity activity, List<ActivityImg> imgs,
			Status status) {
		super(activity);
		this.isSucess = "1";
		this.detailMainImgUrl = activity.getImage();
		this.activityHost = activity.getSponsor();
		this.activityDescription = activity.getDescription();
		if (status == null) {
			this.isInterest = "0";
			this.isParticipate = "0";
		} else if (status.getStatus() == 1) {
			this.isInterest = "1";
			this.isParticipate = "0";
		} else if (status.getStatus() == 2) {
			this.isInterest = "0";
			this.isParticipate = "1";
		} else if (status.getStatus() == 3) {
			this.isInterest = "1";
			this.isParticipate = "1";
		} else{
			this.isInterest = "0";
			this.isParticipate = "0";
		}
		this.allActivityUrl = new ArrayList<String>();
		this.allActivityBigUrl = new ArrayList<String>();
		for (int i = 0; i < imgs.size(); ++i) {
			this.allActivityUrl.add(imgs.get(i).getSmall());
			this.allActivityBigUrl.add(imgs.get(i).getBig());
		}
	}

	public String getIsSucess() {
		return isSucess;
	}

	public void setIsSucess(String isSucess) {
		this.isSucess = isSucess;
	}

	public String getDetailMainImgUrl() {
		return detailMainImgUrl;
	}

	public void setDetailMainImgUrl(String detailMainImgUrl) {
		this.detailMainImgUrl = detailMainImgUrl;
	}

	public String getActivityHost() {
		return activityHost;
	}

	public void setActivityHost(String activityHost) {
		this.activityHost = activityHost;
	}

	public List<String> getAllActivityUrl() {
		return allActivityUrl;
	}

	public void setAllActivityUrl(List<String> allActivityUrl) {
		this.allActivityUrl = allActivityUrl;
	}

	public List<String> getAllActivityBigUrl() {
		return allActivityBigUrl;
	}

	public void setAllActivityBigUrl(List<String> allActivityBigUrl) {
		this.allActivityBigUrl = allActivityBigUrl;
	}

	public String getActivityDescription() {
		return activityDescription;
	}

	public void setActivityDescription(String activityDescription) {
		this.activityDescription = activityDescription;
	}

	public String getIsInterest() {
		return isInterest;
	}

	public void setIsInterest(String isInterest) {
		this.isInterest = isInterest;
	}

	public String getIsParticipate() {
		return isParticipate;
	}

	public void setIsParticipate(String isParticipate) {
		this.isParticipate = isParticipate;
	}

}
